#!/bin/bash

set -e

FILENAME="diamond-girl-${VERSION}.exe"
SIZE=$(du -hs --apparent-size ${FILENAME} | cut --fields=1)
MD5SUM=$(md5sum ${FILENAME} | cut --delimiter=" " --fields=1)
SHA1SUM=$(sha1sum ${FILENAME} | cut --delimiter=" " --fields=1)
echo "<h4>Installer for Windows build</h4>"
echo "<p><a href=\"${FILENAME}\">${FILENAME}</a> (${SIZE})<br>"
echo "Pre-1.24 Diamond Girl settings file (settings.lua) is no longer supported (dropped LUA support for 1.24 Windows version). This means that you will loose your settings, however you will not loose your progress: diamond score, levels opened, traits, and highscores.<br>"
echo "  MD5: <tt>${MD5SUM}</tt><br>"
echo "  SHA1: <tt>${SHA1SUM}</tt><br>"
echo "  Virus-scanned using <a href=\"http://www.clamav.net\">ClamAV</a> <tt>$(clamscan --version | sed 's/ClamAV //g')</tt>:</p>"
echo -n "<pre>"
cat html/clamscan.out
echo "</pre>"
